Skip to content

feat(review): scope reviews by pull request#261

Open
Vaibhaav-Tiwari wants to merge 2 commits into
mainfrom
feat/review-per-pr
Open

feat(review): scope reviews by pull request#261
Vaibhaav-Tiwari wants to merge 2 commits into
mainfrom
feat/review-per-pr

Conversation

@Vaibhaav-Tiwari

Copy link
Copy Markdown
Collaborator

Summary

  • Scope AO review rows and idempotency to (session_id, pr_url) so one workspace session can review multiple PRs independently.
  • Add optional prUrl selection on review list/trigger APIs; single-PR sessions keep the existing no-selector behavior.
  • Return PR-scoped review targets from the list API and regenerate OpenAPI/frontend schema.

Credibility check

Issue #253 is credible on current origin/main: review storage was unique by session_id, while PR storage and workspace sessions allow multiple PRs per session. Two details in the issue were stale: the migration is 0012_add_review_tables.sql on main, not 0011, and ListPRsBySession is already deterministic by updated_at DESC. The core problem remained: review trigger still silently collapsed multi-PR sessions unless PR identity became explicit.

Tests

  • go test -count=1 ./internal/review ./internal/storage/sqlite/store ./internal/httpd/...
  • go test -count=1 ./internal/service/review ./internal/daemon
  • npm --prefix frontend run typecheck

go test ./... was also attempted twice, but timed out after 3 and 5 minutes without emitting a failure in this environment.

Closes #253

@Vaibhaav-Tiwari

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

@Vaibhaav-Tiwari

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

# Conflicts:
#	backend/internal/review/review_test.go
#	backend/internal/storage/sqlite/store/review_store.go
#	backend/internal/storage/sqlite/store/review_store_test.go

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reviews: support multiple PRs per worker session (review keyed by (session, PR), not session)

1 participant